<template>
  <ComPage>
	<template v-slot:nav><uni-nav-bar :class="[proxy.$themeClass('page-bg-color')]" statusBar="true" title="首页"></uni-nav-bar></template>
	<template v-slot:content>
		<view class="flex flex-direction align-center justify-center response">
			<view class="flex flex-direction align-center">
				<image class="logo" src="/static/logo.png"></image>
				<view class="text-bold text-xl">{{ t('common.platform') }}</view>
			</view>
			<button class="cu-btn bg-blue round lg auth-submit" style="width: 80%" @click="onSubmit">
				<image style="width: 64rpx; height: 64rpx;margin-right: 20rpx;" src="/static/img/wechat.svg"></image>
				{{ t('common.wxLoginTip') }}
			</button>
		</view>
	</template>
	<template v-slot:tabbar></template>
  </ComPage>
</template>
<script setup lang="ts">
import { useSlots} from 'vue'
import { useUserStore } from '@/store/user'
import useCurrentInstance from '@/utils/useCurrentInstance'
import ComPage from '@/components/com-page/com-page.vue'
import { useI18n } from 'vue-i18n'
const { t } = useI18n();
console.log(t('home.homeTitle'));
const userStore = useUserStore()
const { proxy } = useCurrentInstance()
const title = ref('Hello')
const slots = useSlots()
console.log(slots);
onBeforeMount(() => {
		console.log('onBeforeMount生命周期')
	})
function onSubmit(){

}
function updateName(str: string) {
  userStore.updateName('sss')
  console.log(proxy)
  proxy.$Router.replaceAll({ name: 'index' })
}
// const props = defineProps({
//   msg: String
// })

// const { title } = toRefs(props)
// console.log(title.value)
</script>

<style>
</style>
